-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix message when leave workshop #774
Conversation
src/app/shared/store/user.state.ts
Outdated
@@ -480,7 +481,9 @@ export class UserState { | |||
|
|||
@Action(OnUpdateApplicationSuccess) | |||
onUpdateApplicationSuccess({ dispatch }: StateContext<UserStateModel>, { payload }: OnUpdateApplicationSuccess): void { | |||
dispatch(new ShowMessageBar({ message: 'Статус заявки успішно змінено', type: 'success' })); | |||
console.log('OnUpdateApplicationSuccess', payload); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove condole log please
src/app/shared/store/user.state.ts
Outdated
dispatch(new ShowMessageBar({ message: 'Статус заявки успішно змінено', type: 'success' })); | ||
console.log('OnUpdateApplicationSuccess', payload); | ||
|
||
dispatch(new ShowMessageBar({ message: payload.status === ApplicationStatus.Left ? `Гурток успішно залишено` : 'Статус заявки успішно змінено', type: 'success' })); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's correct, but I am thinking about creating an enum for different statuses?
When provider reject the application, then there is a text "Заявку успішно відхилено"
Approve -"Заявку успішно прийнято"
etc
We can confirm it with BA.
.vscode/settings.json
Outdated
@@ -1,4 +1,5 @@ | |||
{ | |||
"editor.detectIndentation": false, | |||
"editor.tabSize": 2, | |||
"angular.enable-strict-mode-prompt": false, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why?
src/app/shared/store/user.actions.ts
Outdated
@@ -171,7 +171,7 @@ export class OnUpdateApplicationFail { | |||
} | |||
export class OnUpdateApplicationSuccess { | |||
static readonly type = '[user] update Application success'; | |||
constructor(public payload) { } | |||
constructor(public payload: any) { } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't use the typo "any", it's a bad practice. Add typo of AplicationUpdate, I believe this is the correct one.
change message when leave the workshop